/**
 * 职称ajax
 * @author 陈盼
 * date 2024-01-10 下午 07：06
 */
class Departments {
    /**
     * 查询职称
     * @param departments json实体类
     * @return {Promise<unknown>}
     */
    getAllDepartments(departments){
        return new Promise((resolve, reject) => {

            $.ajax({
                url: "/www.xiaomi.com/background/get/departments",
                method: "GET",
                success: function (response) {
                    resolve(response);
                },
                error: function (error) {
                    reject(error);
                }
            });
        });
    }
}